home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Loadstar 22
/
022.d81
/
haunted house
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-08-26
|
17KB
|
507 lines
1 print"[147]":poke53280,0:poke53281,0
10 if peek(828)<>160 then load"fader.cas.o",8,1
20 gosub700
100 gosub 500 : rem * initialize
110 on rm gosub 1000,2000,3000,4000,5000,6000,7000,8000,9000,10000,11000,12000
120 goto 110
150 goto 110
480 rem *** initialize the game ***
490 :
500 tr=-1 : fa=0 : print"[147][153]";:ch=-1:ni=0:kh=-1:bh=-1:rh=-1:wh=-1:sh=-1:ma=-1
510 poke53280,11 : poke53281,11 : rm=0 :t=rnd(-ti):dim ud(20):mh=-1:sa=-1:sw=10
520 print" [217]ou are standing at the door of the"
530 print"house that has been reputed to be"
540 print"haunted. [193]lthough you don't believe"
550 print"any of the stories you have heard,"
560 print"something bothers you about this place."
570 print"[194]rushing aside your silly intuitions,"
580 print"you decide to enter."
590 print:print"[212]he only entrance is to your north."
600 gosub 20000
610 if dr=0 then 600
620 if dr=1 then rm=1 : return
630 print:print"[193]fter thinking it over, you decide that"
640 print"leaving your mission is not an option." : goto590
698 rem *** title page ***
699 :
700 print"[147]"chr$(142)
710 print" the "
720 print" [209] [209] [209][209][209][209] [209] [209] [209] [209] [209][209][209][209] [209][209][209][209] [209][209][209] "
730 print" [209] [209] [209] [209] [209] [209] [209][209] [209] [209][209] [209] [209] [209] "
740 print" [209][209][209][209] [209][209][209][209] [209] [209] [209][209][209][209] [209][209] [209][209][209] [209] [209] "
750 print" [209] [209] [209] [209] [209] [209] [209] [209][209] [209][209] [209] [209] [209] "
760 print" [209] [209] [209] [209] [209][209] [209] [209] [209][209] [209][209][209][209] [209][209][209] "
770 print" [209] [209] [209][209] [209] [209] [209][209][209][209] [209][209][209][209] "
780 print" [209] [209] [209] [209] [209] [209] [209] [209] "
790 print" [209][209][209][209] [209] [209] [209] [209] [209][209][209][209] [209][209][209] "
800 print" [209] [209] [209] [209] [209] [209] [209] [209] "
810 print" [209] [209] [209][209] [209][209] [209][209][209][209] [209][209][209][209] "
820 print"by joe garrett
830 [153]" loadstar is not public domain."
840 [153]" please respect the author's bytes."
850 [153]" >>> press a key <<<"
890 [158]828:[161]t$
900 [142]
980 [143] *** the entry ***
990 :
1000 [153]:[153]"(NULL)ou are now in the entry hall of the "
1010 [153]"house. (NULL)he dust irritates your nose "
1020 [153]"and cobwebs hang from the ceiling. atn stairway is to your north."
1030 [153]"str$oors are on all other sides."
1035 [139] fo [167] [153]"(NULL)he front door is wide open."
1040 [141] 20000
1042 [139] gt [167] dth[178]2:[137]30000
1045 [139] lk [167] 1000
1046 [139] us [167] [141]26000:[153]"(NULL)othing happened.":[137]1040
1047 [139] dr[178]0 [167] 1040
1050 [139] dr[178]2 [167] rm[178]5:[142]
1060 [139] dr[178]4 [167] rm[178]3:[142]
1070 [139] dr[178]1 [167] [153]"chr$oing up the stairs";:[141]28700 : rm[178]12:[142]
1075 [139] dr[178]3[175]fo [167] [137]55000
1080 [139]dr[178]3[167][153]"right$t's locked. (NULL)ou should never have entered.":[137]1040
1980 [143] *** lower closet ***
1990 :
2000 [153]"(NULL)ower closet."
2010 [153]"(NULL)hese clothes are only seen in movies!"
2020 [153]"chr$lowing letters on the wall read:"
2030 [153]" def(NULL)(NULL)(NULL)closeatn(NULL)valcloselen(NULL)(NULL)(NULL)valstr$close(NULL)right$(NULL)left$close(NULL)left$valclosepeek(NULL)atnlen(NULL)close(NULL)(NULL)(NULL)(NULL)"
2040 [153]" len(NULL)(NULL)(NULL)val.close(NULL)left$val(NULL)valcloseright$(NULL)close(NULL)(NULL)(NULL)close(NULL)(NULL)close(NULL)val(NULL)(NULL)(NULL)(NULL).print"
2050 [153]"(NULL)here is a safe here."
2055 [139] so [167] [153]"right$t is open."
2060 [153]"(NULL)he only exit is north."
2100 [141] 20000
2105 [139] dr[178]2[176]dr[178]3[176]dr[178]4[167][141]27000:[137]2100
2107 [139] dr[178]1 [167] rm[178]3:[142]
2110 [139] lk [167] 2000
2120 [139] ci [167] 2100
2130 [139] gt [167] [153]"(NULL)ou can't get the safe.":[137]2100
2140 [139] us [167] [141] 26000
2150 [139] us$[178]"knife" [167]bk[178][171]1
2160 [139] bk [167]ri$[178]"knife":[141]28000:ai$[178]"bent knife":[141]28500
2170 [139] bk [167] [153]"(NULL)he safe bent the knife!":bk[178]0: [137]2100
2180 [139] us [175] us$[178]"combination"[167][141]50000:[142]
2700 [153]"(NULL)o effect.":[137]2100
3000 [153]"(NULL)he lower bedroom."
3010 [153]"peekefore you is a desk and a twin bed."
3020 [153]"valxits are north, east, and south.
3030 gosub 20000
3040 if lk then 3000
3050 if ci then 3030
3060 if dr=4then gosub27000:goto3030
3070 if dr=1 then rm=6:return
3080 if dr=2 then rm=1:return
3090 if dr=3 then rm=2:return
3100 if gt then print"[212]he furniture would only weigh you down.":goto3030
3110 if us then gosub26000
3120 print"[206]o effect.":goto3030
3980 rem *** the cupboard ***
3990 :
4000 print"[212]he kitchen pantry."
4010 print"[201]t's dark, dusty and full of broken "
4020 print"shelves. [212]he only exit is north."
4030 if bh thenprint"[217]ou barely notice a broom behind one of the shelves."
4040 gosub 20000:ifcithen4040
4042 if us then gosub 26000:ifus$="" then 4040
4043 if us and not mc then print"[212]he "us$" had no effect.":goto4040
4044 if us and mc then print"[193] secret!!!":ai$="treasure":gosub28500:goto55000
4045 if lk then 4000
4050 q= gt and bh
4055 if q then bh=0:ai$="broom":gosub28500:print"[194]room taken.":goto4040
4060 if dr=1 then rm=5:return
4070 if dr<>1 then gosub27000:goto4040
4980 rem *** kitchen ***
4990 :
5000 print"[212]he [203]itchen."
5010 print"[211]mall creatures scatter as you inspect"
5020 print"the cluttered kitchen. "
5030 if kh then print"[212]here is a knife on the table."
5035 if kd thenprint"[211]ome maniac has damaged the kitchen witha knife."
5037 if mz thenprint"[212]he dust from your sweeping makes you sneeze."
5038 print"[212]here are exits to your north, west and south."
5040 gosub 20000
5050 if lk then 5000
5055 if gt and kh then 5110
5057 if gt and not kh then 5120
5058 if us then gosub26000:goto5130
5060 if dr=0 then 5040
5070 if dr=4 then rm=1:return
5080 if dr=1 then rm=7:return
5090 if dr=3 then rm=4:return
5100 if dr=2 then gosub27000:goto5040
5110 print"[203]nife taken.":ni=ni+1:iv$(ni)="knife":kh=0: goto5040
5120 print"[212]he little creatures are worthless. [204]eave them alone.":goto5040
5129 : rem *** use kitchen stuff
5130 if kcthenprint"[212]he knife does significant damage to thekitchen.":kd=-1
5140 if bcthenprint"[212]he dust flies and makes you sneeze more.":mz=-1
5150 if dc thenprint"[212]he little creatures snatch the bat and"
5160 if dc thenprint"drag it into a hole in the wall."
5170 if dc thenri$="bat":gosub28000
5180 print"[217]ou're wasteing time.":goto5040
5980 rem *** the bathroom ***
5990 :
6000 print"[212]he lower bathroom."
6010 print"[217]ou see ordinary bathroom facilities."
6020 if wh then print"[212]here is a witch in here that is not"
6030 if wh then print"pleased with your presence."
6040 if gl then print"[212]here is a piece of gold here."
6045 print"[211]outh is the only exit."
6050 gosub 20000
6060 if lk then 6000
6070 if ci then 6050
6072 if gl and gt then ai$="gold":gosub28500:print"[199]old taken.":gl=0:goto6050
6074 if wh and gt then print"[196]on't even try to get the witch!":goto6050
6080 if dr=2ordr=1ordr=4 thengosub27000:goto6050
6090 q = (dr=3) and wh
6092 z = (dr=3) and not(wh)
6100 if q then dth=3:goto30000
6102 if z then rm=3:return
6110 if us then wu=wu+1:gosub 26000
6115 if wu=3 and wh then 6100
6120 if not wh then print"[206]othing happened.":goto6050
6125 if wh and mc then print"[211]he knows what she looks like!":goto6050
6130 if not(wh and us$="broom")thenprint"[212]he witch is agitated further.":goto6050
6140 print"[193] big smile appears on the witches face."
6150 print"[145][211]he accepts the broom and flys away":wh=0:ri$="broom":gosub28000
6155 print"leaving a piece of gold behind.":gl=-1
6160 goto6050
6980 rem *** the dining room ***
6990 :
7000 print"[21